package com.fei.fpmall.service.bcompany.impl;

import com.fei.fpmall.core.model.Page;
import com.fei.fpmall.dao.bcompany.IBcompanyDao;
import com.fei.fpmall.entity.bcompany.BcompanyEntity;
import com.fei.fpmall.service.bcompany.IBcompanysService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

import com.fei.fpmall.core.dto.ResponseModel;

/**
 * @program: fpmall
 * @description: 开票税号业务实现类
 * @author: felix
 * @create: 2018-04-03 14:33
 **/
@Service("bcompanysService")
public class BcompanysServiceImpl implements IBcompanysService {

    @Autowired
    IBcompanyDao bcompanyDao;

    @Override
    public BcompanyEntity queryObject(Integer bcid) {
        return bcompanyDao.findById(bcid);
    }

    @Override
    public List<BcompanyEntity> queryList(Map<String, Object> map) {
        return null;
    }

    @Override
    public ResponseModel queryListByPage(Map<String, Object> condition, Page page) {
        ResponseModel model = new ResponseModel(0, page);
        List<BcompanyEntity> list = bcompanyDao.queryListByPage(page, condition);
        model.setData(list);
        return model;
    }

    @Override
    public int queryTotal(Map<String, Object> map) {
        return 0;
    }

    @Override
    public void save(BcompanyEntity feiBcompany) {
        bcompanyDao.save(feiBcompany);
    }

    @Override
    public void update(BcompanyEntity feiBcompany) {
        bcompanyDao.update(feiBcompany);
    }

    @Override
    public void delete(Integer bcid) {

    }

    @Override
    public void deleteBatch(Integer[] bcids) {

    }

}
